
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>

<div id="searchDiv" class="ibox " style="display: none;">
	<div class="ibox-title collapse-link" style="cursor: pointer;"
		title="展开/收起查询条件">

		<h5>查询条件</h5>
		<div class="ibox-tools"></div>

	</div>
	
	<form action="web/gLJeHead/getGLJeHeadList" method="get">
	<div class="ibox-content m-b-sm border-bottom">
		<div class="row">
			<div class="col-sm-6">
				<div class="form-group">
					<label class="control-label" for="jeHeadCode">日记账编号</label> 
					<input type="text" id="jeHeadCode" name="jeHeadCode" value="${param.jeHeadCode}" class="form-control">
				</div>
			</div>
			<div class="col-sm-6">
				<div class="form-group">
					<label class="control-label" for="jeName">日记账名称</label> 
					<input type="text" id="jeName" name="jeName" value="${param.jeName}" class="form-control">
				</div>
			</div>
		</div>	
		<div class="row">
			<div class="col-sm-6">
				<div class="form-group">
					<label class="control-label" for="jeType">日记账类型</label> 
					<select id="jeType" name="jeType" class="form-control">
						<option value="">请选择...</option>
						<c:forEach items="${requestScope.jeTypeMap}" var="jeType">
                       		<option value="${jeType.key}">${jeType.value}</option>
                       	</c:forEach>
					</select>
				</div>
			</div>
			<div class="col-sm-6">
				<div class="form-group">
					<label class="control-label" for="jeSource">日记账来源</label> 
					<select id="jeSource" name="jeSource" class="form-control">
						<option value="">请选择...</option>
						<c:forEach items="${requestScope.jeSourceMap}" var="jeSource">
                       		<option value="${jeSource.key}">${jeSource.value}</option>
                       	</c:forEach>
					</select>
				</div>
			</div>
		</div>	
		<div class="row">
			<div class="col-sm-6">
				<div class="form-group">
					<label class="control-label" for="jeStartDate">日记账开始日期</label> 
					<div class="input-group date">
						<span class="input-group-addon"><i class="fa fa-calendar"></i></span>
						<input id="jeStartDate" name="jeStartDate" type="text" class="form-control"
							value="${param.jeStartDate}" autocomplete="off">
					</div>
				</div>
			</div>
			<div class="col-sm-6">
				<div class="form-group">
					<label class="control-label" for="jeEndDate">日记账结束日期</label> 
					<div class="input-group date">
						<span class="input-group-addon"><i class="fa fa-calendar"></i></span>
						<input id="jeEndDate" name="jeEndDate" type="text" class="form-control"
							value="${param.jeEndDate}" autocomplete="off">
					</div>
				</div>
			</div>
		</div>
		<div class="row">
			<div class="col-sm-6">
				<div class="form-group">
					<label class="control-label" for="postStatus">过账状态</label> 
					<select name="postStatus" id="postStatus" class="form-control">
						<option value="" selected="">请选择</option>
						<option value="Y">已过账</option>
						<option value="N">未过账</option>
					</select>
				</div>
			</div>
			<div class="col-sm-6">
				<div class="form-group">
					<label class="control-label" for="status">状态</label> 
					<select id="status" name="status" class="form-control">
						<option value="">请选择...</option>
						<c:forEach items="${requestScope.statusMap}" var="status">
                       		<option value="${status.key}">${status.value}</option>
                       	</c:forEach>
					</select>
				</div>
			</div>
		</div>
		<div class="row">
			<div class="col-sm-12 text-right">
				<div class="form-group">
					<button type="submit" class="btn btn-w-m btn-primary">查询</button>
				</div>
			</div>
		</div>
	</div>
	
	<%-- 隐藏字段 --%>
	<input type="hidden" name="page" value="1">
	</form>
</div>

<script>
$(document).ready(function(){
	//设置状态默认值
	if("${param.status}"!=""){
		$("#status").val("${param.status}");
	}
	//设置postStatus默认值
	if("${param.postStatus}"!=""){
		$("#postStatus").val("${param.postStatus}");
	}
	//设置jeSource默认值
	if("${param.jeSource}"!=""){
		$("#jeSource").val("${param.jeSource}");
	}
	//设置jeType默认值
	if("${param.jeType}"!=""){
		$("#jeType").val("${param.jeType}");
	}
	
	//设置日期插件
	$('#jeStartDate').datepicker({
		todayBtn : "linked",
		keyboardNavigation : true,
		forceParse : true,
		calendarWeeks : false,
		autoclose : true,
		format: 'yyyy-mm-dd',
		language: 'zh-CN',
	});
	
		//设置日期插件
	$('#jeEndDate').datepicker({
		todayBtn : "linked",
		keyboardNavigation : true,
		forceParse : true,
		calendarWeeks : false,
		autoclose : true,
		format: 'yyyy-mm-dd',
		language: 'zh-CN',
	});
});
</script>
